Adds saturation fraction#2149
Conversation
precipitable water
James Warner (jwarner8)
left a comment
There was a problem hiding this comment.
Looks good, a few small queries/clarifications.
| # (following trapezoid rule). | ||
| pw = np.trapezoid( | ||
| w.data, | ||
| x=w.coord("level_height").points[:], |
There was a problem hiding this comment.
Does model always use "level_height" as coordinate name for model levels? Realise this is for the UM, with LFRic data needing to be fixed to include this auxilliary coordinate alongside model_level_number.
| ) | ||
| # Determine array information of input cube to get | ||
| # correct cube to copy across to. | ||
| if len(w.coord("realization").points) != 1 and len(w.coord("time").points) != 1: |
There was a problem hiding this comment.
are we making assumptions of the cube structure/how dimensions are ordered?
There was a problem hiding this comment.
I think there is some code somewhere in CSET which returns the axis names and which index they are. It might be in one of Huw's merged branches. If we do assume a structure, be good to be clear about this in code in comments so easier to debug later on
|
|
||
| It can be calculated as | ||
|
|
||
| .. math:: spw = frac{1}{\rho_w} \int \frac{w}{RH} dz |
There was a problem hiding this comment.
any ref/book citation we can use to ground this?
|
|
||
| and can be used throughout the globe with the same interpretation. | ||
|
|
||
| For a recent, example, [Daviesetal2026]_ have applied the concept to their |
There was a problem hiding this comment.
| For a recent, example, [Daviesetal2026]_ have applied the concept to their | |
| For a recent example, [Daviesetal2026]_ have applied the concept to their |
| precipitable water are derived, before their ratios are taken for the | ||
| saturation fraction. | ||
|
|
||
| A saturation fraction close to one implies that the atmopshere is fully |
There was a problem hiding this comment.
| A saturation fraction close to one implies that the atmopshere is fully | |
| A saturation fraction close to one implies that the atmosphere is fully |
| operator: constraints.combine_constraints | ||
| constraint_1: | ||
| operator: constraints.generate_var_constraint | ||
| varname: "m01s00i408" |
There was a problem hiding this comment.
will this work on LFRic data as it wont have STASH attributes?
Also includes operators for precipitable water and saturation precipitable water as needed within saturation fraction code.
Fixes #1965
Contribution checklist
Aim to have all relevant checks ticked off before merging. See the developer's guide for more detail.
rose-suite.conf.examplehas been updated if new diagnostic added.